import 'package:get/get.dart';

import '../../category/controllers/category_controller.dart';
import '../../main/controllers/main_controller.dart';
import '../../service/controllers/service_controller.dart';
import '../../shopcar/controllers/shopcar_controller.dart';
import '../../user/controllers/user_controller.dart';
import '../controllers/home_controller.dart';

//HomeBinding中可以初始化多个Controller，不同的子页面view可以使用对应的Controller
class HomeBinding extends Bindings {
  @override
  void dependencies() {
    Get.lazyPut<HomeController>(
      () => HomeController(),
    );
    Get.lazyPut<CategoryController>(
      () => CategoryController(),
    );
    Get.lazyPut<MainController>(
      () => MainController(),
    );
    Get.lazyPut<ShopcarController>(
      () => ShopcarController(),
    );
    Get.lazyPut<ServiceController>(
      () => ServiceController(),
    );
    Get.lazyPut<UserController>(
      () => UserController(),
    );
  }
}
